class CreateMovies < ActiveRecord::Migration
    def self.up
        create_table :movies do |t|
            t.string :title
            t.integer :year
            t.string :language
            t.decimal :rating, :precision => 3, :scale => 1
            t.boolean :seen

            t.timestamps
        end

        Movie.create( :title => 'Hello Brother',
                :year => 2005,
                :language => 'Hindi',
                :rating => 6.2,
                :seen => false
                )
    end

    def self.down
        drop_table :movies
    end
end
